﻿package Message.Public
{
    import Engine.RMI.*;
    import Framework.Serialize.*;

    public class ECareer extends Object
    {
        public var __value:int;
        public static const _ECareerNo:int = 0;
        public static const _ECareerWarrior:int = 1;
        public static const _ECareerArcher:int = 2;
        public static const _ECareerMage:int = 4;
        public static const _ECareerPriest:int = 8;
        public static const _ECareerWarriorEx:int = 16;
        public static const _ECareerArcherEx:int = 32;
        public static const _ECareerMageEx:int = 64;
        public static const _ECareerPriestEx:int = 128;
        public static const _ECareerPhysPet:int = 256;
        public static const _ECareerMagicPet:int = 512;

        public function ECareer(param1:int)
        {
            this.__value = param1;
            return;
        }// end function

        public function value() : int
        {
            return this.__value;
        }// end function

        public function __write(param1:SerializeStream) : void
        {
            param1.writeShort(this.__value);
            return;
        }// end function

        public static function convert(param1:int) : ECareer
        {
            return new ECareer(param1);
        }// end function

        public static function __read(param1:SerializeStream) : ECareer
        {
            var _loc_2:* = param1.readShort();
            if (_loc_2 < 0 || _loc_2 >= 513)
            {
                throw new MarshalException();
            }
            return ECareer.convert(_loc_2);
        }// end function

    }
}
